#include <cstdio>
#include <cstring>

int main( )
{
    char d[ 100 ];
    int v, c, i;
    bool cor, hv;
    while ( gets( d ) )
    {
        if ( strcmp( d, "end" ) == 0 )
            break;
        cor = true;
        hv = false;
        v = c = 0;
        for ( i = 0; i < strlen( d ); i++ )
        {
            if ( d[ i ] == 'a' || d[ i ] == 'e' || d[ i ] == 'i' || d[ i ] == 'o' || d[ i ] == 'u' )
            {
                hv = true;
                v++;
                c = 0;
            }
            else
            {
                c++;
                v = 0;
            }
            if ( v == 3 || c == 3 )
            {
                cor = false;
                break;
            }
            if ( d[ i ] == d[ i + 1 ] )
                if ( d[ i ] != 'e' && d[ i ] != 'o' )
                {
                    cor = false;
                    break;
                }
        }
        if ( cor && hv )
            printf("<%s> is acceptable.\n", d);
        else
            printf("<%s> is not acceptable.\n", d);
    }
    return 0;
}
